package com.an.blog.web.controller;

import cn.dev33.satoken.annotation.SaIgnore;
import com.an.blog.service.IBlogUserService;
import com.an.blog.web.domain.vo.BlogAuthorInfoVo;
import com.an.common.core.domain.R;
import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * 博客用户信息web控制器
 *
 * @author: Ann
 * @createDate: 2023/11/16 14:32:20
 * @version: 1.0.0
 */

@RestController
@RequestMapping("/blog-web/user")
@RequiredArgsConstructor
public class BlogUserInfoWebController {

    private final IBlogUserService blogUserService;

    /**
     * 查询博客作者信息
     *
     * @return {@link R }<{@link BlogAuthorInfoVo }>
     * @author: Ann
     * @createDate: 2023/11/16 14:36:08
     * @version: 1.0.0
     */
    @SaIgnore
    @GetMapping("/queryAuthor")
    public R<BlogAuthorInfoVo> queryBlogAuthorInfo() {
        return R.ok(blogUserService.queryBlogAuthorInfo());
    }

}
